home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
FishMarket 1.0
/
FishMarket v1.0.iso
/
fishies
/
301-325
/
disk_319
/
cnewssrc
/
cnews.orig.lzh
/
expire
/
dircheck
next >
Wrap
Text File
|
1989-06-27
|
516b
|
33 lines
#! /bin/sh
# dircheck -- checker for expire regression testing
case "$1" in
-n) invert=yes ; shift ;;
esac
for f in `sed 's/.* //;s/\./\//g'`
do
if test " $invert" = " "
then
if test ! -f $1/$f
then
echo "cannot find $1/$f" >&2
exit 1
fi
it="`cat $1/$f`"
if test " $it" = " $f" || expr " $it" : ".*:$f:.*" >/dev/null
then
: okay
else
echo "contents of $1/$f are wrong" >&2
exit 1
fi
else
if test -f $1/$f
then
echo "found $1/$f, shouldn't have" >&2
exit 1
fi
fi
done